From 2700e324924c263e079a8e73a39f58a2d0a967af Mon Sep 17 00:00:00 2001 From: "emellor@leeni.uk.xensource.com" Date: Thu, 2 Mar 2006 21:45:13 +0100 Subject: [PATCH] Cope if xenstore is down. Signed-off-by: Ewan Mellor --- tools/xenstore/xenstore_control.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tools/xenstore/xenstore_control.c b/tools/xenstore/xenstore_control.c index 5433bfc811..0be80261e4 100644 --- a/tools/xenstore/xenstore_control.c +++ b/tools/xenstore/xenstore_control.c @@ -22,6 +22,11 @@ int main(int argc, char **argv) xsh = xs_daemon_open(); + if (xsh == NULL) { + fprintf(stderr, "Failed to contact Xenstored.\n"); + return 1; + } + xs_debug_command(xsh, argv[1], NULL, 0); xs_daemon_close(xsh); -- 2.30.2